﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace 租车
{
    class Car:Vehicle
    {
      public  Car(string col,double dr,string ln,string nam,int ys): base(col,dr,ln,nam,ys)
        {
            Type = 1;
        }
      public override double cal(int d,int l)
      {
          if (d <= 30)
              return d * DailyRent;
          else if (d > 30)
              return 30 * DailyRent + 1.1 * DailyRent * (d - 30);
          else return 0;
      }
      public override int getload()
      {
          return 0;
      }
    }
}
